package com.zy.springboot.entity.user;

import com.alibaba.fastjson.JSONObject;
import com.zy.springboot.entity.BaseEntity;

import javax.persistence.Entity;
import javax.persistence.Table;
import java.io.Serializable;

/**
 * Created by y on 2019/1/16.
 */
@Entity
@Table(name = "T_SYS_YZM", schema = "booksearch", catalog = "")
public class YzmEntity extends BaseEntity implements Serializable {
    private String tel;//手机号
    private String yzm;//验证码

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel;
    }

    public String getYzm() {
        return yzm;
    }

    public void setYzm(String yzm) {
        this.yzm = yzm;
    }

    @Override
    public JSONObject getJSONObject() {
        JSONObject obj = new JSONObject();
        obj.put("ID", this.getId());
        obj.put("TEL", this.getTel());
        obj.put("YZM", this.getYzm());
        obj.put("CREATE_TIME", this.getCreateTime());
        return obj;
    }

    @Override
    public String getTableName() {
        return "T_SYS_YZM";
    }

    @Override
    public JSONObject getJSONColumns() {
        JSONObject obj = new JSONObject();
        obj.put("ID", "id");
        obj.put("TEL", "tel");
        obj.put("YZM", "yzm");
        obj.put("CREATE_TIME", "createTime");
        return obj;
    }
}
